@echo off
REM ******************************************************************
REM * This script signs a jar file using the certificate 
REM * defined in the signer.properties file
REM * 
REM * This script can be run as often as is required on any jar
REM * A backup copy of the jar file is created
REM ******************************************************************
REM * 18-JUN-2003 DRMILLS - Creation
REM ******************************************************************

for /F "eol=# tokens=1,2* delims==" %%i in (signer.properties) do set %%i=%%j

copy /Y %1 %1.unsigned
@echo on
"%JDK_HOME%\bin\jarsigner" -keystore "%JINIT_HOME%\lib\security\keystore" -storepass jinitiator -keypass %JAR_KEY_PASSWORD% %1 %JAR_KEY%
@echo Signing complete...